//
// Created by liushuai on 18-8-7.
//

#include "acctabc.hpp"
#include <string>
acctabc::acctabc(const std::string &s, long an, double bal) {
    fullName = s;
    acctNum = an;
    balance = bal;
}
long acctabc::AccNum() const {
    return acctNum;
}
const std::string& acctabc::FullName() const {
    return fullName;
}
double acctabc::Balance() const {
    return balance;
}
void acctabc::Deposit(double amt) {
    if(amt<0)
        std::cout<<"不允许负数存款"<<"\n";
    else
        balance += amt;
}
void acctabc::Withdraw(double amt) {
    balance -= amt;
}